<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
        PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html">

 <ui:composition template="/templates/common.xhtml">
     <ui:define name="title">Регистрация</ui:define>
     <ui:define name="content">
         <h1>Регистрация</h1>
         <h:form>
             <h:panelGrid columns="3">
                 <h:outputLabel for="login" value="Имя пользователя (логин):"/>
                 <h:inputText id="login" value="#{accountRegisterBean.account.login}"/>
                 <h:message for="login"/>

                 <h:outputLabel for="password" value="Пароль:"/>
                 <h:inputSecret id="password" value="#{accountRegisterBean.account.password}"/>
                 <h:message for="password"/>

                 <h:outputLabel for="email" value="Email:"/>
                 <h:inputText id="email" value="#{accountRegisterBean.account.email}"/>
                 <h:message for="email"/>

                 <h:outputLabel for="captchaimg" value="Капча:"/>
                 <h:graphicImage id="captchaimg" value="/CaptchaImage"/>
                 <h:message for="captchaimg"/>

                 <h:outputLabel for="captchaval" value="Текст с картинки:"/>
                 <h:inputText id="captchaval" value="#{accountRegisterBean.captchaValue}"/>
                 <h:message for="captchaval"/>
             </h:panelGrid>

             <h:commandButton action="#{accountRegisterBean.doRegister}" value="Зарегистрироваться"/>
         </h:form>
     </ui:define>
 </ui:composition>
 </html>
